import requests

from common.DBUtil import DBUtil
from common.get_headers_util import get_headers


def get_id_until():
    # 链接数据库删除对应号码
    DBUtil.uid_db("delete from bs_user where mobile='19999321321';")
    get_id = requests.post(url="http://ihrm2-test.itheima.net/api/sys/user",
                                   headers=get_headers(),
                                   json={"username":"张三","mobile":"19999321321","workNumber":"3450845309"})
    em_id=get_id.json().get("data").get("id")
    return em_id

if __name__=='__main__':
    print(get_id_until())